home *** CD-ROM | disk | FTP | other *** search
/ Champak 120 / Vol 120.iso / games / anacroz.swf / scripts / __Packages / Item.as < prev    next >
Encoding:
Text File  |  2010-11-09  |  790 b   |  51 lines

  1. class Item
  2. {
  3.    var cod;
  4.    var nome;
  5.    var poder;
  6.    var tipo;
  7.    var valor;
  8.    var equipado;
  9.    function Item(cd, n, p, t, v)
  10.    {
  11.       this.cod = cd;
  12.       this.nome = n;
  13.       this.poder = p;
  14.       this.tipo = t;
  15.       this.valor = v;
  16.       this.equipado = false;
  17.    }
  18.    function equip()
  19.    {
  20.       this.equipado = true;
  21.    }
  22.    function unEquip()
  23.    {
  24.       this.equipado = false;
  25.    }
  26.    function getCod()
  27.    {
  28.       return this.cod;
  29.    }
  30.    function getNome()
  31.    {
  32.       return this.nome;
  33.    }
  34.    function getPoder()
  35.    {
  36.       return this.poder;
  37.    }
  38.    function getValor()
  39.    {
  40.       return this.valor;
  41.    }
  42.    function getTipo()
  43.    {
  44.       return this.tipo;
  45.    }
  46.    function isEquiped()
  47.    {
  48.       return this.equipado;
  49.    }
  50. }
  51.